﻿// Decompiled with JetBrains decompiler
// Type: MG_Cooler.GeneratedBuildings_LoadGeneratedBuildings
// Assembly: MG_Cooler, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null
// MVID: 7560BFF2-5E64-4596-AB14-3DB707CE39FE
// Assembly location: E:\docs\Klei\OxygenNotIncluded\mods\Steam\2573951847\MG_Cooler.dll

using HarmonyLib;
using STRINGS;

namespace MG_Cooler
{
  [HarmonyPatch("LoadGeneratedBuildings")]
  [HarmonyPatch(typeof (GeneratedBuildings))]
  public static class GeneratedBuildings_LoadGeneratedBuildings
  {
    public static void Prefix()
    {

      GeneratedBuildings_LoadGeneratedBuildings.AddStrings("MGCooler", MGCoolerConfig.Name, MGCoolerConfig.CNDescription, MGCoolerConfig.CNEffect);
      GeneratedBuildings_LoadGeneratedBuildings.AddStrings("MGWaterCooler", MGWaterCoolerConfig.Name, MGWaterCoolerConfig.CNDescription, MGWaterCoolerConfig.CNEffect);
      

      ModUtil.AddBuildingToPlanScreen((HashedString) "Utilities", "MGCooler");
      ModUtil.AddBuildingToPlanScreen((HashedString) "Utilities", "MGWaterCooler");
    }

    public static void AddStrings(string ID, string Name, string Description, string Effect)
    {
      Strings.Add("STRINGS.BUILDINGS.PREFABS." + ID.ToUpperInvariant() + ".NAME", UI.FormatAsLink(Name, ID));
      Strings.Add("STRINGS.BUILDINGS.PREFABS." + ID.ToUpperInvariant() + ".DESC", Description);
      Strings.Add("STRINGS.BUILDINGS.PREFABS." + ID.ToUpperInvariant() + ".EFFECT", Effect);
    }
  }
}
